<?php

/**
 * @package		Joomla
 * @subpackage	wbfirst
 * @copyright	2008 Wim Bekker, www.wimbekker.com.
 * @license		GNU/GPL
*/
 
// no direct access
defined( '_JEXEC' ) or die( 'Restricted access' );
 
jimport( 'joomla.application.component.model' );
 
// classname'Model'modelname
class WbfirstModelWbfirst extends JModel
{
    /**
    * Gets the greeting
    * @return string The greeting to be displayed to the user
    */
    function getGreeting()
    {
      $db =& JFactory::getDBO();
      $sql = 'SELECT greeting FROM #__wbfirst';
      $db->setQuery($sql);
      $greeting = $db->loadResult();
      if ($greeting == null)
      {
        $greeting = 'db not found';
      }
      
      return $greeting;
    }
}
?>
